package tianxiao.web.test.common;

import org.springframework.stereotype.Component;
import yun.web.springmvc.ReqAtta;

import javax.servlet.http.HttpServletRequest;


/*------------------------
      author: 张天笑
      date: 2019/3/20
      携带自己想要的数据到形参
-------------------------*/
@Component
public class HelloReqAtta implements ReqAtta<String> {
    String data;

    @Override
    public String get() {
        return data;
    }

    @Override
    public void init(HttpServletRequest req) {
        this.data = "Hello ReqAtta";
    }
}
